﻿using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;

public class StringResources
{
    public readonly bool IsEnglish;

    public readonly string Error;
    public readonly string Message;

    public readonly string Synchronized;
    public readonly string Synchronizing;
    public readonly string Unsynchronized;

    public readonly string DeviceIsNotReady;

    public readonly string Firmware;
    public readonly string Upgrade;
    public readonly string NoNeedUpgrade;
    public readonly string PleaseUpgrade;
    public readonly string FileNotFound;

    public readonly string Channel;

    public readonly string Parameter;
    public readonly string PleaseDownloadParameter;

    public readonly string Total;
    public readonly string Passed;
    public readonly string Failed;

    public readonly string Barcode;
    public readonly string CellBarcode;
    public readonly string Model;
    public readonly string TestResult;
    public readonly string TestTime;

    public readonly string InsertToSQL;
    public readonly string NotConnected;
    public readonly string Disable;

    public readonly string DataNotSave;

    public readonly string DataCanNotBeBlank;

    public readonly string OperationDone;

    public readonly string MDBInserted;
    public readonly string MDBFailed;

    public readonly string BarcodeRuleError;


    public readonly string ParameterManagement;
    public readonly string CheckManagement;
    public readonly string ParameterPassword;
    public readonly string CheckPassword;

    public StringResources()
    {
        if(Language.CurrentLCID == Language.LCID.ENG)
        {
            #region English
            Error = "Error";
            Message = "Message";
            Synchronized = "Synchronized";
            Synchronizing = "Synchronizing...";
            Unsynchronized = "Unsynchronized";
            DeviceIsNotReady = "Device Is Not Ready";
            Upgrade = "Upgrade";
            FileNotFound = "File Not Found!";
            Firmware = "Firmware";
            NoNeedUpgrade = "No Need Upgrade";
            PleaseUpgrade = "Please Upgrade";
            Channel = "Channel";
            Parameter = "Parameter";

            Total = "Total";
            Passed = "PASSED";
            Failed = "FAILED";

            Barcode = "Barcode";
            CellBarcode = "Cell Barcode";
            Model = "Model";
            TestResult = "TestResult";
            TestTime = "TestTime";
            PleaseDownloadParameter = "Please download the parameter first!";

            InsertToSQL = "SQL Server";
            NotConnected = "Not Connected";

            Disable = "Disable";

            DataNotSave = "Some data has not been saved to the database yet!";

            DataCanNotBeBlank = "Data can not be blank!";

            OperationDone = "Done!";

            MDBInserted = "MDB Inserted";
            MDBFailed = "MDB Failed";

            BarcodeRuleError = "Failure to meet the rule of Barcode";



        
            #endregion
        }
        else
        {
            Error = "错误";
            Message = "信息";
            Synchronized = "已同步";
            Synchronizing = "同步中...";
            Unsynchronized = "未同步";
            DeviceIsNotReady = "设备未就绪";
            Upgrade = "升级";
            FileNotFound = "文件不存在";
            Firmware = "固件";
            NoNeedUpgrade = "无需升级";
            PleaseUpgrade = "需要升级";
            Channel = "通道";
            Parameter = "设置参数";
            Total = "总数";
            Passed = "测试通过";
            Failed = "测试失败";
            Barcode = "成品条码";
            CellBarcode = "电芯条码";
            Model = "型号";
            TestResult = "结论";
            TestTime = "日期时间";
            PleaseDownloadParameter = "请先下载设置参数!";
            InsertToSQL = "SQL Server";
            NotConnected = "尚未连接数据库";
            Disable = "未使用";
            DataNotSave = "有一些尚未保存到数据库中!";
            DataCanNotBeBlank = "数据不能为空!";
            OperationDone = "操作成功!";

            MDBInserted = "MDB成功";
            MDBFailed = "MDB失败";

            BarcodeRuleError = "条码不符合规则";

            if (Language.CurrentLCID == Language.LCID.CHT)
            {
                Error = Language.ToCHT(Error);
                Message = Language.ToCHT(Message);
                Synchronized = Language.ToCHT(Synchronized);
                Synchronizing = Language.ToCHT(Synchronizing);
                Unsynchronized = Language.ToCHT(Unsynchronized);
                DeviceIsNotReady = Language.ToCHT(DeviceIsNotReady);
                Upgrade = Language.ToCHT(Upgrade);
                FileNotFound = Language.ToCHT(FileNotFound);
                Firmware = Language.ToCHT(Firmware);
                NoNeedUpgrade = Language.ToCHT(NoNeedUpgrade);
                PleaseUpgrade = Language.ToCHT(PleaseUpgrade);
                Channel = Language.ToCHT(Channel);
                Parameter = Language.ToCHT(Parameter);
                Passed = Language.ToCHT(Passed);
                Failed = Language.ToCHT(Failed);
                Barcode = Language.ToCHT(Barcode);
                CellBarcode = Language.ToCHT(CellBarcode);
                Model = Language.ToCHT(Model);
                TestResult = Language.ToCHT(TestResult);
                TestTime = Language.ToCHT(TestTime);
                PleaseDownloadParameter = Language.ToCHT(PleaseDownloadParameter);
                InsertToSQL = Language.ToCHT(InsertToSQL);
                NotConnected = Language.ToCHT(NotConnected);
                Disable = Language.ToCHT(Disable);
                DataNotSave = Language.ToCHT(DataNotSave);
                DataCanNotBeBlank = Language.ToCHT(DataCanNotBeBlank);
                OperationDone = Language.ToCHT(OperationDone);
                MDBInserted = Language.ToCHT(MDBInserted);
                MDBFailed = Language.ToCHT(MDBFailed);
                BarcodeRuleError = Language.ToCHT(BarcodeRuleError);
            }
        }
        #region  常量
      
        #endregion
    }
}
